<?php 
$bg=json_decode(file_get_contents('https://www.zydx.win/date/lypp/api.php?'.http_build_query($_POST)),true);?>
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title><?php echo $bg['bzname']?>六爻排盘3333</title>


<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimum-scale=1.0, maximum-scale=1.0">
<meta name="apple-mobile-web-app-capable" content="yes">
<meta name="format-detection" content="telephone=no">
<meta name="applicable-device" content="pc,mobile">
<meta http-equiv="Cache-Control" content="no-transform">
<meta http-equiv="Cache-Control" content="no-siteapp">
<meta name="apple-mobile-web-app-status-bar-style" content="black">
<link rel="stylesheet" href="date/list.css">
<script type="text/javascript" src="date/jquery-1.10.2.min.js"></script>
</head>
<body>

<article>
<section>

https://www.zydx.win/  调用文档有api
<div class="hd pp_more_s"><i></i>基本信息<span data-s="0">&and;</span></div>
<div class="baseinfo">
<div class="bd">
	<div class="item dis_flex">
			<div class="flex dis_flex">
				<span class="tit">姓名：</span>
				<div class="text flex"><?php echo $bg['bzname']?></div>
			</div>
			<div class="flex dis_flex">
				<span class="tit">性别：</span>
				<div class="text flex"><?php echo $bg['sex']?'男':'女'?></div>
			</div>
			<div class="flex dis_flex">
				<span class="tit">占事：</span>
				<div class="text flex"><?php echo $bg['anything']?></div>
			</div>
		</div>
		<?php if($bg['zty']):?>
		<div class="item dis_flex">
			<span class="tit">北京时：</span>
			<div class="text flex"><small>公历<?php echo $bg['glstr']?><br>农历<?php echo $bg['nlstr']?></small></div>
		</div>
		<div class="item dis_flex">
			<span class="tit">太阳时：</span>
			<div class="text flex"><small>公历<?php echo $bg['truedatestr']?><br>农历<?php echo $bg['zty_nlstr']?></small></div>
		</div>
		<?php else:?>
		<div class="item dis_flex">
			<span class="tit">卦时：</span>
			<div class="text flex"><small>公历<?php echo $bg['glstr']?><br>农历<?php echo $bg['nlstr']?></small></div>
		</div>
		<?php endif;
		if(!empty($bg['area'])):?>
		<div class="item dis_flex">
			<span class="tit">起卦地：</span>
			<div class="text flex">
				<?php echo $bg['area'];?>
			</div>
		</div>
		<?php endif;?>
		<div class="item dis_flex">
			<span class="tit">节气：</span>
			<div class="text flex"><small><?php echo $bg['prejqname'];?><br><?php echo $bg['curjqname'];?></small></div>
		</div>
		<div class="item dis_flex">
			<span class="tit">八字：</span>
			<div class="text flex"><font color="red"><?php echo $bg['ygz']."&emsp;".$bg['mgz']."&emsp;".$bg['dgz']."&emsp;".$bg['hgz'];?></font></div>
		</div>
		<div class="item dis_flex">
			<div class="text flex">驿马:<?php echo $bg['maxing'];?>&emsp;桃花:<?php echo $bg['taohua'];?>&emsp;日禄:<?php echo $bg['lu'];?>&emsp;贵人:<?php echo $bg['guiren'][0].$bg['guiren'][1];?></div>
		</div>
	</div>
</div>
</section>
<section>
<div class="hd ui-cells"><i></i>六爻卦盘<span>日空：<?php echo $bg['xkong'];?></span></div>
<div class="pp6y clearfix">
	<ul>
	<li><?php echo $bg['bagua_pp'][0];?></li>
	<?php 
	$benclass="class='beng1'";
	$bianclass="class='bian1'";
	if($bg['isfu']):
	$benclass="class='beng0'";
	$bianclass="class='bian0'";
	?>
	<li class="fu">
	<?php echo $bg['bagua_pp'][1];?>
	</li>
	<?php endif;?>
	<li <?php echo $benclass;?>>
	<?php echo $bg['bagua_pp'][2];?>
	</li>
	<?php if($bg['isbian']):?>
	<li <?php echo $bianclass;?>>
	<?php echo $bg['bagua_pp'][3];?>
	</li>
	<?php endif;?>
	</ul>
</div>


<div class="pp6y clearfix">
	<ul>
	<li><?php echo $bg['bagua_pp'][0]; //六神   ?></li> 
	
	<?php 
	$benclass="class='beng1'";
	$bianclass="class='bian1'";
	if($bg['isfu'])://如果是有
	$benclass="class='beng0'";
	$bianclass="class='bian0'";
	//伏卦   ?>


	<li class="fu">
	<?php echo $bg['bagua_pp'][1]; //伏卦 ?>
	</li>


	<?php endif;?>
	<li <?php echo $benclass;?>>
	<?php echo $bg['bagua_pp'][2]; //六静卦 ?>
	</li>


	<?php if($bg['isbian']):?>
	<li <?php echo $bianclass;?>>
	<?php echo $bg['bagua_pp'][3]; //变卦  ?>
	</li>


	<?php endif;?>

	
	</ul>
</div>


</section>








	<?php echo $bg['bagua_pp'][0].$bg['isfu']; //六神   
	
	echo  strval($bg['bagua_pp'][1]); //伏卦
	
	echo $bg['bagua_pp'][2];
	echo $bg['bagua_pp'][3];
	echo $benclass;
	echo $bianclass;
	?>

	

	


<section>
<div class="hd ui-cells pp_more_s"><i></i>爻辞<span data-s="1">&or;</span></div>
<div class="yaoci none">
<?php echo $bg['yaoci']['z']?><br>
<?php if($bg['yaoci']['b']!='')echo '<br>'.$bg['yaoci']['b']?>
</div>
</section>
</article>

<script>
$('.pp_more_s').click(function(){
		var that=$(this).find('span');
		var s=that.data('s');
		if(s==0) that.html("&and;");
		else that.html("&or;");
		var d=(s+1)%2;
		that.data('s',d);
		$(this).next().slideToggle(500);
	}
);
</script>
</body>
</html>